// use 可以在循环里用

import { use } from "react";
const messages = [
  Promise.resolve("hello"),
  Promise.resolve("world"),
  Promise.resolve("react"),
];
function App() {
  const dataList = messages.map((message, index) => {
    const data = use(message);
    return (
      <div key={index}>
        消息{index + 1}:{data}
      </div>
    );
  });
  return <div>{dataList}</div>;
}
export default App;
